/*
 * @Author: zxc
 * @Date: 2020-07-23 13:07:57
 * @LastEditTime: 2020-08-13 13:51:47
 * @LastEditors: zxc
 * @Description: 只接收两个reducer 一个是sagareducer 一个是thunkreducer
 */

import { combineReducers } from "redux";
import {connectRouter} from 'connected-react-router'
import { History } from 'history';
import sagaReducer from "./saga/reducer";
import thunkReducer from './thunk/reducers'
//combineReducers接收一个对象，对象里面是一个个小的reducer
const rootReducer =(history:History) =>  combineReducers({
  router:connectRouter(history),
  ...sagaReducer,
  ...thunkReducer
});

export default rootReducer;
